﻿@model LbangCMS.ViewModels.ProductDetailModel
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
}
@{ Html.RenderPartial("_InnerBanner");}
<div class="gx_p_content container">
    <div class="row">
        <div class="gx_p_content_left am-animation-slide-left" data-am-scrollspy="{animation: 'slide-left'}">
            <div class="gx_p_left_top hidden-in"><h2 class="gx_p_left_tittle">产品展示</h2><span class="gx_p_left_letter">PRODUCT</span></div>
            <ul class="gx_p_left_nav clearfix">
                @if (Model.Categories != null && Model.Categories.Any())
                {
                    foreach (var item in Model.Categories)
                    {
                        if (item.ID == Model.CurrentCategoryId)
                        {
                            <li><a class="gx_p_nav_on" href="#">@item.Name<i class="fa icon-left hidden-in"></i></a></li>
                        }
                        else
                        {
                            <li><a href="@Url.Action("Index","Product",new { categoryId=item.ID})">@item.Name<i class="fa icon-left hidden-in"></i></a></li>
                        }
                    }
                }
            </ul>
            <div class="gx_p_recommend hidden-in">
                <h3 class="gx_p_recommend_tittle"><b></b><span>推荐商品</span></h3>
                <ul class="gx_p_recommend_list">
                    @if (Model.RecommendProducts != null && Model.RecommendProducts.Any())
                    {
                        foreach (var item in Model.RecommendProducts)
                        {
                            <li><a class="gx_p_recommend_img" href=""><img src="@item.ImageSrc" alt="" /></a><a class="gx_p_recommend_text" href="">@item.Name</a><em></em></li>
                        }
                    }
                   
                </ul>
            </div>
        </div>
    </div>
    <div class="gx_p_content_right am-animation-scale-up" data-am-scrollspy="{animation: 'scale-up'}">
        <div class="gx_p_right_top">
            <div class="gx_p_right_title"><strong class="gx_p_right_name">产品展示</strong><span class="gx_p_right_letter">PRODUCT<i class="fa icon_small"></i></span></div>
            <div class="gx_p_right_position hidden-in"><i class="fa icon-position"></i><a href="index.html">首页</a>><a href="@Url.Action("Index","Product",new { categoryId=Model.CurrentCategoryId }) ">产品展示</a>><a href="#">产品详情</a></div>
        </div>
        <div class="gx_p_right_main">
            <div class="gx_p_product_details clearfix">
                <div class="gx_p_details_img middles-4"><img src="@Model.Product.ImageSrc" alt="" /></div>
                <div class="gx_p_details_text middles-8">
                    <h2 class="gx_p_details_tittle">@Model.Product.Name</h2>
                    @if (Model.Properties != null && Model.Properties.Any())
                    {
                        foreach (var item in Model.Properties.OrderBy(o=>o.SortIndex))
                        {
                            <p>@item.PropertyName ： @item.PropertyValue</p>
                        }
                    }
                </div>
            </div>
            <div class="gx_p_right_top">
                <div class="gx_p_right_title"><strong class="gx_p_right_name">商品描述</strong><span class="gx_p_right_letter">Description<i class="fa icon_small"></i></span></div>
            </div>
            <div class="gx_p_details_explain">
               @Html.Raw(Model.Product.Description)
            </div>
        </div>
    </div>
</div>